<?php

/**
 * Object used to manage customers and their information
 * 
 * @package Customer
 * @author Guillem Mateos
 * @version 0.1
 * @abstract 
 * @copyright GRITO2003, S.L.
 */

/**
 * includes
 */
//include_once( '../library/config.php' );
include_once( FROG_DATABASE.'DBObject.class.php' );

class Category extends DBObject
{
  /**
  * Initialize vars
  */
  public function initVars( )
  {
    $this->dbfields['id_category'] = null;
    $this->dbfields['name'] = null;
    $this->dbfields['visible'] = null;
    
    $this->dbparams['table'][0] = 'category';
    $this->dbparams['main_id'] = 'id_category';
  }
  
  public static function findVisible( )
  {   
    $c = new Category();
        
    $w_expr_01 = new Expression( 'visible', '=', '1' );

    $result = $c->select( '', $w_expr_01  );
    
    return $result;
  }
} 

?>